<!DOCTYPE html>
<!--[if IE 8]> <html lang="en" class="ie8 no-js"> <![endif]-->
<!--[if IE 9]> <html lang="en" class="ie9 no-js"> <![endif]-->
<!--[if !IE]><!--> <html lang="en" class="no-js"> <!--<![endif]-->
<!-- BEGIN HEAD -->
<head>
	<meta charset="utf-8" />
	<title>{$Think.lang.mwt_page_title} - {$Think.lang.cfg_website}</title>
	<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,user-scalable=0" />
	<meta content="" name="description" />
	<meta content="" name="author" />
	<!-- BEGIN GLOBAL MANDATORY STYLES -->
	<link href="{$NOW_THEME_URL}/Assets/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/plugins/bootstrap/css/bootstrap-responsive.min.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/css/style-metro.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/css/style.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/css/style-responsive.css" rel="stylesheet" type="text/css"/>
	<link href="{$NOW_THEME_URL}/Assets/css/themes/{:session('skin')}.css" rel="stylesheet" type="text/css" id="style_color"/>
	<!-- END GLOBAL MANDATORY STYLES -->
	<!-- BEGIN PAGE LEVEL STYLES -->
	<!-- END PAGE LEVEL STYLES -->
	<link rel="shortcut icon" href="favicon.ico" />
</head>
<!-- END HEAD -->
<!-- BEGIN BODY -->
<body class="page-header-fixed">
	<!-- BEGIN HEADER -->
	<include file="Public:header" />
	<!-- END HEADER -->
	<!-- BEGIN CONTAINER -->
	<div class="page-container">
		<!-- BEGIN SIDEBAR -->
		<div class="page-sidebar nav-collapse collapse">
			<!-- BEGIN SIDEBAR MENU -->        
			<ul class="page-sidebar-menu">
            	<li>
					<!-- BEGIN SIDEBAR TOGGLER BUTTON -->
					<div class="sidebar-toggler hidden-phone"></div>
					<!-- BEGIN SIDEBAR TOGGLER BUTTON -->
				</li>
                {$menu_tree}
            </ul>
			<!-- END SIDEBAR MENU -->
		</div>
		<!-- END SIDEBAR -->
		<!-- BEGIN PAGE -->
		<div class="page-content">
			<!-- BEGIN SAMPLE PORTLET CONFIGURATION MODAL FORM-->
			<div id="portlet-config" class="modal hide">
				<div class="modal-header">
					<button data-dismiss="modal" class="close" type="button"></button>
					<h3>portlet Settings</h3>
				</div>
				<div class="modal-body">
					<p>Here will be a configuration form</p>
				</div>
			</div>
			<!-- END SAMPLE PORTLET CONFIGURATION MODAL FORM-->
			<!-- BEGIN PAGE CONTAINER-->        
			<div class="container-fluid">
				<!-- BEGIN PAGE HEADER-->
				<div class="row-fluid">
					<div class="span12">
						<!-- BEGIN PAGE TITLE & BREADCRUMB-->
						<div class="clear">&nbsp;</div>
						<ul class="breadcrumb">
							<li>
								<i class="icon-home"></i>
								<a href="__APP__">{$Think.lang.cfg_page_home}</a> 
								<span class="icon-angle-right"></span>
							</li>
							<li>
								<a href="#">{$Think.lang.mwt_page_title}</a> 
								<span class="icon-angle-right"></span>
						  </li>
						</ul>
						<!-- END PAGE TITLE & BREADCRUMB-->
					</div>
				</div>
				<!-- END PAGE HEADER-->
				<!-- BEGIN PAGE CONTENT-->
      <div class="row-fluid">
        <div class="alert alert-info"  style="margin-bottom:0px;">
          <button class="close" data-dismiss="alert"></button>
          {$Think.lang.mwt_form_tis_2}
        </div>
      </div>
	<div class="row-fluid">
        <form class="form-horizontal" method="post" action="__URL__/menu" id="adcontentForm">
          <div class="span4">
            <div class="portlet box blue">
              <div class="portlet-title">
                <div class="caption"><i class="icon-th"></i> {$Think.lang.mwt_form_tis_menu}1</div>
              </div>
              <div class="portlet-body" style="line-height:40px;">
                <input type="text" name="subject[up][0][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['name']}">
                <input type="text" name="cmd[up][0][cmd]" placeholder="{$Think.lang.mwt_form_cmd}" 
                 class="m-wrap small" value="{$json[0]['key']}">
                <br/>
                {$Think.lang.mwt_form_tis_1}
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}1"/>
                <select name="type[sub][0][0][type]" class="type_menu m-wrap span4" val="{$json[0]['sub_button'][0]['type']}"></select>
                <input type="text" name="subject[sub][0][0][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['sub_button'][0]['name']}">
                <input type="text" name="cmd[sub][0][0][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[0]['sub_button'][0]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}2"/>
                <select name="type[sub][0][1][type]" class="type_menu m-wrap span4" val="{$json[0]['sub_button'][1]['type']}"></select>
                <input type="text" name="subject[sub][0][1][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['sub_button'][1]['name']}">
                <input type="text" name="cmd[sub][0][1][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[0]['sub_button'][1]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}3"/>
                <select name="type[sub][0][2][type]" class="type_menu m-wrap span4" val="{$json[0]['sub_button'][2]['type']}"></select>
                <input type="text" name="subject[sub][0][2][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['sub_button'][2]['name']}">
                <input type="text" name="cmd[sub][0][2][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[0]['sub_button'][2]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}4"/>
                <select name="type[sub][0][3][type]" class="type_menu m-wrap span4" val="{$json[0]['sub_button'][3]['type']}"></select>
                <input type="text" name="subject[sub][0][3][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['sub_button'][3]['name']}">
                <input type="text" name="cmd[sub][0][3][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[0]['sub_button'][3]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}5"/>
                <select name="type[sub][0][4][type]" class="type_menu m-wrap span4" val="{$json[0]['sub_button'][4]['type']}"></select>
                <input type="text" name="subject[sub][0][4][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[0]['sub_button'][4]['name']}">
                <input type="text" name="cmd[sub][0][4][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[0]['sub_button'][4]['key']}">
                <br/>
              </div>
            </div>
          </div>
          <div class="span4">
            <div class="portlet box blue">
              <div class="portlet-title">
                <div class="caption"><i class="icon-th"></i> {$Think.lang.mwt_form_tis_menu}2</div>
              </div>
              <div class="portlet-body" style="line-height:40px;">
                <input type="text" name="subject[up][1][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['name']}">
                <input type="text" name="cmd[up][1][cmd]" placeholder="{$Think.lang.mwt_form_cmd}" 
                 class="m-wrap small" value="{$json[1]['key']}">
                <br/>
                
                {$Think.lang.mwt_form_tis_1}
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}1"/>
                <select name="type[sub][1][0][type]" class="type_menu m-wrap span4" val="{$json[1]['sub_button'][0]['type']}"></select>
                <input type="text" name="subject[sub][1][0][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['sub_button'][0]['name']}">
                <input type="text" name="cmd[sub][1][0][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[1]['sub_button'][0]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}2"/>
                <select name="type[sub][1][1][type]" class="type_menu m-wrap span4" val="{$json[1]['sub_button'][1]['type']}"></select>
                <input type="text" name="subject[sub][1][1][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['sub_button'][1]['name']}">
                <input type="text" name="cmd[sub][1][1][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[1]['sub_button'][1]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}3"/>
                <select name="type[sub][1][2][type]" class="type_menu m-wrap span4" val="{$json[1]['sub_button'][2]['type']}"></select>
                <input type="text" name="subject[sub][1][2][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['sub_button'][2]['name']}">
                <input type="text" name="cmd[sub][1][2][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[1]['sub_button'][2]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}4"/>
                <select name="type[sub][1][3][type]" class="type_menu m-wrap span4" val="{$json[1]['sub_button'][3]['type']}"></select>
                <input type="text" name="subject[sub][1][3][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['sub_button'][3]['name']}">
                <input type="text" name="cmd[sub][1][3][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span" value="{$json[1]['sub_button'][3]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}5"/>
                <select name="type[sub][1][4][type]" class="type_menu m-wrap span4" val="{$json[1]['sub_button'][4]['type']}"></select>
                <input type="text" name="subject[sub][1][4][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[1]['sub_button'][4]['name']}">
                <input type="text" name="cmd[sub][1][4][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[1]['sub_button'][4]['key']}">
                <br/>
              </div>
            </div>
          </div>
          <div class="span4">
            <div class="portlet box blue">
              <div class="portlet-title">
                <div class="caption"><i class="icon-th"></i> {$Think.lang.mwt_form_tis_menu}3</div>
              </div>
              <div class="portlet-body" style="line-height:40px;">
                <input type="text" name="subject[up][2][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['name']}">
                <input type="text" name="cmd[up][2][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap small" value="{$json[2]['key']}">
                <br/>
                {$Think.lang.mwt_form_tis_1}
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}1"/>
                <select name="type[sub][2][0][type]" class="type_menu m-wrap span4" val="{$json[2]['sub_button'][0]['type']}"></select>
                <input type="text" name="subject[sub][2][0][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['sub_button'][0]['name']}">
                <input type="text" name="cmd[sub][2][0][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[2]['sub_button'][0]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}2"/>
                <select name="type[sub][2][1][type]" class="type_menu m-wrap span4" val="{$json[2]['sub_button'][1]['type']}"></select>
                <input type="text" name="subject[sub][2][1][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['sub_button'][1]['name']}">
                <input type="text" name="cmd[sub][2][1][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[2]['sub_button'][1]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}3"/>
                <select name="type[sub][2][2][type]" class="type_menu m-wrap span4" val="{$json[2]['sub_button'][2]['type']}"></select>
                <input type="text" name="subject[sub][2][2][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['sub_button'][2]['name']}">
                <input type="text" name="cmd[sub][2][2][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[2]['sub_button'][2]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}4"/>
                <select name="type[sub][2][3][type]" class="type_menu m-wrap span4" val="{$json[2]['sub_button'][3]['type']}"></select>
                <input type="text" name="subject[sub][2][3][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['sub_button'][3]['name']}">
                <input type="text" name="cmd[sub][2][3][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[2]['sub_button'][3]['key']}">
                <br/>
                
                <input type="text" readonly class="m-wrap" style="width:50px;" value="{$Think.lang.mwt_form_tis_menu}5"/>
                <select name="type[sub][2][3][type]" class="type_menu m-wrap span4" val="{$json[2]['sub_button'][4]['type']}"></select>
                <input type="text" name="subject[sub][2][4][name]" placeholder="{$Think.lang.mwt_form_placeholder_menu}" 
                 class="m-wrap small" value="{$json[2]['sub_button'][4]['name']}">
                <input type="text" name="cmd[sub][2][4][cmd]" placeholder="{$Think.lang.mwt_form_placeholder_cmd}" 
                 class="m-wrap span10" value="{$json[2]['sub_button'][4]['key']}">
                <br/>
              </div>
            </div>
          </div>
          <div class="form-actions" style="padding-left:0px;">
      <button type="submit" class="btn blue"><i class="icon-ok"></i> {$Think.lang.mwt_form_ele_submit}</button>
      <button type="button" class="btn green chat_menu"><i class=" icon-indent-right"></i> {$Think.lang.mwt_form_ele_create}</button>
      <!--<button type="button" class="btn red"><i class=" icon-remove"></i> {$Think.lang.mwt_form_ele_delete}</button>-->
          </div>
        </form>
      </div>			
				<!-- END PAGE CONTENT-->
			</div>
			<!-- END PAGE CONTAINER-->
		</div>
		<!-- END PAGE -->
	</div>
	<!-- END CONTAINER -->
	<!-- BEGIN FOOTER -->
    <include file="Public:footer" />
	<!-- END FOOTER -->
	<!-- BEGIN JAVASCRIPTS(Load javascripts at bottom, this will reduce page load time) -->
	<!-- BEGIN CORE PLUGINS -->
	<script src="__PUBLIC__/Js/jquery.min.js" type="text/javascript"></script>
	<script src="{$NOW_THEME_URL}/Assets/plugins/jquery-migrate-1.2.1.min.js" type="text/javascript"></script>   
	<script src="{$NOW_THEME_URL}/Assets/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
	<!--[if lt IE 9]>
	<script src="{$NOW_THEME_URL}/Assets/plugins/excanvas.min.js"></script>
	<script src="{$NOW_THEME_URL}/Assets/plugins/respond.min.js"></script>  
	<![endif]-->  
	<script src="{$NOW_THEME_URL}/Assets/plugins/jquery.cookie.min.js" type="text/javascript"></script>
	<!-- END CORE PLUGINS -->
	<!-- BEGIN PAGE LEVEL PLUGINS -->
	<!-- END PAGE LEVEL PLUGINS -->
	<!-- BEGIN PAGE LEVEL SCRIPTS -->
	<script src="{$NOW_THEME_URL}/Assets/scripts/app.js"></script>   
	<script type="text/javascript">
		var ABS_URL_Theme  = "{$NOW_THEME_URL}/";
		var ABS_URL_Module = "__URL__";
		var list_itf       = {};
		
		jQuery(document).ready(function() {       
		   App.init();
		   
		   $('.chat_menu').live('click',function(){
				$.get('{:U("/Public/chat_menu")}',function(data){
					if(data.errcode == 0){
						alert('{$Think.lang.mwt_form_dtis_succ}');
					}else{
						alert('{$Think.lang.mwt_form_dtis_fail}');
					}
				},"json");
			});
		   
		   var option = "<option value='view'>{$Think.lang.mwt_form_type_view}</option><option value='click'>{$Think.lang.mwt_form_type_click}</option>";
		   $('.type_menu').each(function(){
			   $(this).html(option);
			   var val = $(this).attr("val");
			   if(!val){
				   val = "view";
			   }
			   $(this).val(val);
		   });
		});
	</script>
	<!-- END JAVASCRIPTS -->   
</body>
<!-- END BODY -->
</html>